OTOpenAppleTalkServices
Opens a synchronous AppleTalk service provider.C INTERFACE
ATSvcRef OTOpenAppleTalkServices (OTConfiguration* cfig, OTOpenFlags flags, OSStatus* err);C++ INTERFACE
None. C++ clients use the C interface to this function.PARAMETERS
cfig
- A pointer to a configuration structure that specifies the AppleTalk service provider's characteristics. You can obtain this pointer by using the constant
kDefaultAppleTalkServicesPath
for this parameter. This directs Open Transport to create an AppleTalk service provider on the default hardware port, which is the one selected in the AppleTalk control panel.flags
- Reserved. Set to 0.
err
- A pointer to a variable of type
OSStatus
that holds the result code for this function. A value of 0 (noErr
) indicates successful completion.DESCRIPTION
TheOTOpenAppleTalkServices
function opens an AppleTalk service provider and gives you a unique AppleTalk service provider reference for it. This function also sets the mode of all subsequently called AppleTalk service provider functions as synchronous.Because the
OTOpenAppleTalkServices
function operates synchronously, it is recommended that you use theOTAsyncOpenAppleTalkServices
function instead.
- WARNING
- The
OTOpenAppleTalkServices
function destroys the configuration structure returned by theOTCreateConfiguration
function. You may not use the same configuration structure to open multiple AppleTalk service providers. To obtain a valid copy of the configuration structure to use for opening another AppleTalk service provider, use theOTCloneConfiguration
function.![]()
SPECIAL CONSIDERATIONS
When you no longer need to use AppleTalk service provider functions, you must call the generic Open Transport functionOTCloseProvider
.SEE ALSO
To open a provider asynchronously, use theOTAsyncOpenAppleTalkServices
function (page 11-11).To create a copy of the configuration structure used to open an AppleTalk service provider, use the
OTCloneConfiguration
function, described in the chapter "Configuration Management" in this book.To close the AppleTalk service provider, call the
OTCloseProvider
function, described in the chapter "Providers" in this book.